package com.hdax.dm.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.hdax.dm.mappers.SchedulerMapper;
import com.hdax.dm.mappers.SchedulerPriceMapper;
import com.hdax.dm.scheduler.DmSchedulerSeatPrice;
import com.hdax.dm.service.SchedulerPriceService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SchedulerPriceServiceImpl extends ServiceImpl<SchedulerPriceMapper, DmSchedulerSeatPrice> implements SchedulerPriceService {


    @Override
    public List<DmSchedulerSeatPrice> SchedulerPrices(String scheduleId) {
        QueryWrapper wrapper = new QueryWrapper<>();
        wrapper.eq("scheduleId",scheduleId);
        return list(wrapper);
    }

    @Override
    public List<DmSchedulerSeatPrice> SchedulerPrices(Long scheduleId, Long areaLevel) {
        QueryWrapper wrapper = new QueryWrapper<>();
        wrapper.eq("scheduleId",scheduleId);
        wrapper.eq("areaLevel",areaLevel);
        return list(wrapper);
    }
}
